<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
	<head>
		<meta charset="utf-8">
		<title>日记编辑</title>
		<link rel="stylesheet" href="../../../static/layui/css/layui.css" th:href="@{/layui/css/layui.css}"/>
		<link rel="stylesheet" type="text/css" href="../../../static/layui/css/common.css" th:href="@{/layui/css/common.css}"/>
		<link rel="stylesheet" type="text/css" href="../../../static/layui/css/diarycss/diary-edit.css" th:href="@{/layui/css/diarycss/diary-edit.css}"/>
	</head>
	<body>
	<!-- 公共头部 -->
	<div th:replace="FrontPages/common/head::head(n=5)" name="headFrame"></div>

		<div class="diary-index">
			<div class="diary-head">
				<ul class="layui-nav">
					<li class="layui-nav-item layui-this">
						<a onclick="opened(this);" th:value="1">我的日记</a>
					</li>
					<li class="layui-nav-item">
						<a onclick="opened(this);" th:value="0">私密日记</a>
					</li>
				</ul>
			</div>
			<!-- 日记 -->
			<div class="diary-index-box">
				<div class="diary-index-main">
					<!-- 功能 -->
					<div class="diary-index-button">
						<textarea></textarea>
						<div class="diary-pulish">
							<span>可见范围</span>
							<select>
								<option value="1">所有人可见</option>
								<option value="0">仅自己可见</option>
							</select>
							<button id="but">发表</button>
							<span th:id="font-num">0/255</span>
						</div>
					</div>

					<!-- 日记列表 -->
					<div class="diary-index-list">
						<ul>
							<li th:each="diary,diaryStat:${diaries}">
								<div class="diary-list-content">
									<span>&nbsp;&nbsp;&nbsp;</span>
									<span th:text="${diary.content}"></span>
								</div>
								<div class="diary-list-status">
									<span th:id="time" th:text="${diary.date}">2019-6-8</span>
									<span th:id="ledit">编辑
										<i class="layui-icon"></i></span>
										<ul class="management-list layui-anim layui-anim-upbit" th:value="${diary.did}">
											<li onclick="click1(this);">删除</li>
											<li onclick="click2(this);">修改</li>
											<li onclick="click3(this);">设为私密</li>
										</ul>
								</div>
							</li>
						</ul>
						<div th:id="test1"></div>
					</div>
				</div>

				<!-- 分类 -->
				<div class="diary-index-class">
					<div class="diary-class-head">
						<div class="diary-class-avatar">
							<img src="../../../static/layui/images/head-pic/head1.jpg" th:src="${session.user.img}"/>
						</div>
						<b th:text="${session.user.name?:session.user.uid}">瑞克</b>
						<div class="diary-class-span">
							<a th:text="${num1}">2</a><span>篇日记</span><br />
							<a th:text="${num2}">0</a><span>篇私密日记</span>
						</div>
					</div>
					<div class="diary-bless">
						<!-- <img src="../../../static/layui/images/2222.jpg" /> -->
						<span th:id="bless-left">岁月静好</span>
						<span th:id="bless-right">难得糊涂</span>
					</div>
				</div>
			</div>
		</div>

		<!-- 公共尾部 -->
		<div th:replace="FrontPages/common/bottom::bottom" name="bottomFrame"></div>
		<script type="text/jscript" src="../../../static/layui/layui.js" th:src="@{/layui/layui.js}"></script>
		<script type="text/jscript" src="../../../static/layui/lay/js/diary.js" th:src="@{/layui/lay/js/diary.js}"></script>

		<!-- 背景特效 -->
		<script src="../../../static/layui/lineEffects.js" th:src="@{/layui/lineEffects.js}"></script>
	</body>
</html>
